3.6.25 \(\int \sqrt {a+a \sin (e+f x)} \, dx\) [525]

Optimal. Leaf size=26 \[ -\frac {2 a \cos (e+f x)}{f \sqrt {a+a \sin (e+f x)}} \]

[Out]

-2*a*cos(f*x+e)/f/(a+a*sin(f*x+e))^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 26, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.071, Rules used = {2725} \begin {gather*} -\frac {2 a \cos (e+f x)}{f \sqrt {a \sin (e+f x)+a}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + a*Sin[e + f*x]],x]

[Out]

(-2*a*Cos[e + f*x])/(f*Sqrt[a + a*Sin[e + f*x]])

Rule 2725

Int[Sqrt[(a_) + (b_.)*sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[-2*b*(Cos[c + d*x]/(d*Sqrt[a + b*Sin[c + d*x
]])), x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rubi steps

\begin {align*} \int \sqrt {a+a \sin (e+f x)} \, dx &=-\frac {2 a \cos (e+f x)}{f \sqrt {a+a \sin (e+f x)}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(65\) vs. \(2(26)=52\).
time = 0.02, size = 65, normalized size = 2.50 \begin {gather*} \frac {2 \left (-\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right ) \sqrt {a (1+\sin (e+f x))}}{f \left (\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right )} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + a*Sin[e + f*x]],x]

[Out]

(2*(-Cos[(e + f*x)/2] + Sin[(e + f*x)/2])*Sqrt[a*(1 + Sin[e + f*x])])/(f*(Cos[(e + f*x)/2] + Sin[(e + f*x)/2])
)

________________________________________________________________________________________

Maple [A]
time = 1.80, size = 43, normalized size = 1.65

method result size
default \(\frac {2 \left (1+\sin \left (f x +e \right )\right ) a \left (\sin \left (f x +e \right )-1\right )}{\cos \left (f x +e \right ) \sqrt {a +a \sin \left (f x +e \right )}\, f}\) \(43\)
risch \(-\frac {i \sqrt {2}\, \sqrt {-a \left (-2-2 \sin \left (f x +e \right )\right )}\, \left ({\mathrm e}^{i \left (f x +e \right )}-i\right ) \left ({\mathrm e}^{i \left (f x +e \right )}+i\right )}{\left ({\mathrm e}^{2 i \left (f x +e \right )}+2 i {\mathrm e}^{i \left (f x +e \right )}-1\right ) f}\) \(74\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sin(f*x+e))^(1/2),x,method=_RETURNVERBOSE)

[Out]

2*(1+sin(f*x+e))*a*(sin(f*x+e)-1)/cos(f*x+e)/(a+a*sin(f*x+e))^(1/2)/f

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^(1/2),x, algorithm="maxima")

[Out]

integrate(sqrt(a*sin(f*x + e) + a), x)

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 55 vs. \(2 (26) = 52\).
time = 0.33, size = 55, normalized size = 2.12 \begin {gather*} -\frac {2 \, \sqrt {a \sin \left (f x + e\right ) + a} {\left (\cos \left (f x + e\right ) - \sin \left (f x + e\right ) + 1\right )}}{f \cos \left (f x + e\right ) + f \sin \left (f x + e\right ) + f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^(1/2),x, algorithm="fricas")

[Out]

-2*sqrt(a*sin(f*x + e) + a)*(cos(f*x + e) - sin(f*x + e) + 1)/(f*cos(f*x + e) + f*sin(f*x + e) + f)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \sqrt {a \sin {\left (e + f x \right )} + a}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))**(1/2),x)

[Out]

Integral(sqrt(a*sin(e + f*x) + a), x)

________________________________________________________________________________________

Giac [A]
time = 0.46, size = 38, normalized size = 1.46 \begin {gather*} \frac {2 \, \sqrt {2} \sqrt {a} \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )}{f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^(1/2),x, algorithm="giac")

[Out]

2*sqrt(2)*sqrt(a)*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e))*sin(-1/4*pi + 1/2*f*x + 1/2*e)/f

________________________________________________________________________________________

Mupad [B]
time = 7.42, size = 33, normalized size = 1.27 \begin {gather*} -\frac {2\,\cos \left (e+f\,x\right )\,\sqrt {a\,\left (\sin \left (e+f\,x\right )+1\right )}}{f\,\left (\sin \left (e+f\,x\right )+1\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a*sin(e + f*x))^(1/2),x)

[Out]

-(2*cos(e + f*x)*(a*(sin(e + f*x) + 1))^(1/2))/(f*(sin(e + f*x) + 1))

________________________________________________________________________________________